package com.dog.dao.impl;

import com.dog.dao.UserDAO;
import com.dog.model.User;
import org.hibernate.SessionFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import javax.annotation.PostConstruct;

/**
 * User: Dmitriy Akishin
 * Date: 08.03.2010
 * Time: 14:06:06
 */

@Repository
public class UserDAOImpl extends DAOImpl<User> implements UserDAO{

    @Autowired
    private SessionFactory sessionFactory;

    public UserDAOImpl() {
        super(User.class);
    }

    @PostConstruct
    private void initialze() {
        this.setSessionFactory(sessionFactory);
    }
}
